import { Body, Controller, Post } from '@nestjs/common';
import { RolesService } from './roles.service';
import { Roles } from './modules/roles.entity';

@Controller('roles')
export class RolesController {
    constructor(private readonly rolesService: RolesService) {}

    @Post()
    async addUser(@Body() dto: any): Promise<any>{
        const roles = dto as Roles
        return await this.rolesService.create(roles);
    }
}
